package com.example;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 阿宾
 * Date: 2025-04-03
 * Time: 16:19
 */
@RestController //标识当前类是一个请求处理类
public class HelloController {
    //返回值表示给前端响应的数值
    @RequestMapping("/hello")//标识请求路径
    public String hello(String name){
        System.out.println("name: "+name);
        return "Hello "+name +"~";
    }
}
